<!DOCTYPE html>

<html lang="zh-cn">

<head>
    <meta charset="utf-8">
    <title>Div Test</title>
    <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
    <link href="../../assets/css/main.css" rel="stylesheet" />
    <style>
        .bg {
            border: 1px solid #555;
            background-color: #aaa;
        }
    </style>
</head>

<body>
    <script src="../../node_modules/three/build/three.js"></script>
    <script src="../../dist/ShadowEditor.js"></script>
    <script>
        var control = Shadow.UI.create({
            xtype: 'div',
            cls: 'bg',
            style: {
                color: 'red'
            },
            children: [{
                xtype: 'html',
                html: 'Hello, world!'
            }],
            onClick: function () {
                UI.msg('You clicked div!');
            }
        });

        control.render();
    </script>
</body>

</html>